package com.itany.ums.service;

import com.itany.ums.entity.User;
import com.itany.ums.exception.RequestParameterErrorException;
import com.itany.ums.exception.UserExistException;
import com.itany.ums.exception.UserNotExistException;

/**
 * Author:shixiaojun@itany.com
 * Date:2022/3/10 9:23
 * Version:1.0-SNAPSHOT
 */
public interface UserService {

    /**
     * 用户注册
     * @param username
     * @param password
     * @param phone
     * @param address
     */
    public void register(String username,String password,String phone,String address) throws RequestParameterErrorException, UserExistException;

    /**
     * 用户登录
     * @param username
     * @param password
     * @return
     */
    public User login(String username,String password) throws RequestParameterErrorException, UserNotExistException;
}
